import 'package:wanxiang_app/generated/json/base/json_convert_content.dart';
import 'package:wanxiang_app/bean/recrod_ids_entity.dart';

RecrodIdsEntity $RecrodIdsEntityFromJson(Map<String, dynamic> json) {
  final RecrodIdsEntity recrodIdsEntity = RecrodIdsEntity();
  final String? channelId = jsonConvert.convert<String>(json['channelId']);
  if (channelId != null) {
    recrodIdsEntity.channelId = channelId;
  }
  final String? time = jsonConvert.convert<String>(json['time']);
  if (time != null) {
    recrodIdsEntity.time = time;
  }
  final List<String>? ids = (json['ids'] as List<dynamic>?)?.map(
          (e) => jsonConvert.convert<String>(e) as String).toList();
  if (ids != null) {
    recrodIdsEntity.ids = ids;
  }
  return recrodIdsEntity;
}

Map<String, dynamic> $RecrodIdsEntityToJson(RecrodIdsEntity entity) {
  final Map<String, dynamic> data = <String, dynamic>{};
  data['channelId'] = entity.channelId;
  data['time'] = entity.time;
  data['ids'] = entity.ids;
  return data;
}

extension RecrodIdsEntityExtension on RecrodIdsEntity {
  RecrodIdsEntity copyWith({
    String? channelId,
    String? time,
    List<String>? ids,
  }) {
    return RecrodIdsEntity()
      ..channelId = channelId ?? this.channelId
      ..time = time ?? this.time
      ..ids = ids ?? this.ids;
  }
}